﻿// Original author contact info: Owen Emlen (owene_1998@yahoo.com)
// Note: other individuals may also have contributed to this code
// Project hosted on CodePlex.com as of 1/10/2009 at http://wpfimageviewer.codeplex.com
using System;
using System.Collections.Generic;
using BrainTechLLC.ImageOperatorsNonAForgeDependent;
using System.Collections.ObjectModel;
using System.Collections.Specialized;
using System.ComponentModel;
using System.Diagnostics;
using System.Drawing;
using System.Drawing.Imaging;
using System.IO;
using System.Linq;
using AForge.Imaging;
using AForge.Imaging.Filters;
using BrainTechLLC;
using BrainTechLLC.ImageOperators;

namespace BrainTechLLC.FilterExtensions
{
    public partial class FilterCollection : ObservableCollection<ISingleFilter>, ICanApply, INotifyPropertyChanged, IPostProcessor
    {
        protected FastSmartWeakEvent<EventHandler<NotifyCollectionChangedEventArgs>> _generationChanged = new FastSmartWeakEvent<EventHandler<NotifyCollectionChangedEventArgs>>();
        public event EventHandler<NotifyCollectionChangedEventArgs> GenerationChanged { add { _generationChanged.Add(value); } remove { _generationChanged.Remove(value); } }

        protected FastSmartWeakEvent<EventHandler<ObjectEventArgs<Bitmap, string>>> _beginFilterBitmap = new FastSmartWeakEvent<EventHandler<ObjectEventArgs<Bitmap, string>>>();
        public event EventHandler<ObjectEventArgs<Bitmap, string>> BeginFilterBitmap { add { _beginFilterBitmap.Add(value); } remove { _beginFilterBitmap.Remove(value); } }

        protected FastSmartWeakEvent<EventHandler<ObjectEventArgs<Bitmap, string, string, ISingleFilter>>> _beforeFilterBitmap = new FastSmartWeakEvent<EventHandler<ObjectEventArgs<Bitmap, string, string, ISingleFilter>>>();
        public event EventHandler<ObjectEventArgs<Bitmap, string, string, ISingleFilter>> BeforeFilterBitmap { add { _beforeFilterBitmap.Add(value); } remove { _beforeFilterBitmap.Remove(value); } }

        protected FastSmartWeakEvent<EventHandler<ObjectEventArgs<Bitmap, string, string, ISingleFilter>>> _afterFilterBitmap = new FastSmartWeakEvent<EventHandler<ObjectEventArgs<Bitmap, string, string, ISingleFilter>>>();
        public event EventHandler<ObjectEventArgs<Bitmap, string, string, ISingleFilter>> AfterFilterBitmap { add { _afterFilterBitmap.Add(value); } remove { _afterFilterBitmap.Remove(value); } }
   }
}